package com.example.crt_dispatching_center.dto;

import java.util.Comparator;
import java.util.List;

public class StaPassengerLingerDTO {

    private List<Station> stationList;

    public List<Station> getStationList() {
        return stationList;
    }

    public void setStationList(List<Station> stationList) {
        stationList.sort(Comparator.comparingDouble(Station::getLinger));
        this.stationList = stationList;
    }

}
class Station{
    private String name;
    private float linger;


    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public float getLinger() {
        return linger;
    }

    public void setLinger(float linger) {
        this.linger = linger;
    }
}
